
using System;
using System.Collections.Generic;
using System.Linq.Expressions;
using System.Threading.Tasks;
using CoreCms.Net.Model.Entities;
using CoreCms.Net.Model.ViewModels.Basics;
using CoreCms.Net.Model.ViewModels.UI;
using SqlSugar;

namespace CoreCms.Net.IServices
{
    /// <summary>
    /// 用户日历签到统计 服务工厂接口
    /// </summary>
    public interface ICoreCmsUserCheckInServices : IBaseServices<CoreCmsUserCheckIn>
    {
        #region 重写根据条件查询分页数据
        /// <summary>
        ///     重写根据条件查询分页数据
        /// </summary>
        /// <param name="predicate">判断集合</param>
        /// <param name="orderByType">排序方式</param>
        /// <param name="pageIndex">当前页面索引</param>
        /// <param name="pageSize">分布大小</param>
        /// <param name="orderByExpression"></param>
        /// <param name="blUseNoLock">是否使用WITH(NOLOCK)</param>
        /// <returns></returns>
        Task<IPageList<CoreCmsUserCheckIn>> QueryPageAsync(
           Expression<Func<CoreCmsUserCheckIn, bool>> predicate,
           Expression<Func<CoreCmsUserCheckIn, object>> orderByExpression, OrderByType orderByType, int pageIndex = 1,
           int pageSize = 20, bool blUseNoLock = false);
        #endregion

        /// <summary>
        /// 定时清理用户连续签到信息
        /// </summary>
        /// <returns></returns>
        Task<AdminUiCallBack> ClearUserContinuousCheckIn();

    }
}
